package com.longma.server.service.impl;
import com.longma.server.service.IFileService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletResponse;

@Slf4j
@Service
public class FileServiceImpl extends  AbstrctFileService implements IFileService {

    private static final String SYS_ROOT_PATH = "system";

    /**
     * 文件上传
     */
    @Override
    public String uploadFile(MultipartFile file) {
        return super.uploadFile(file, SYS_ROOT_PATH);
    }

    /**
     * 文件下载
     */
    @Override
    public void downloadFile(HttpServletResponse response, String fileName) {
        super.downloadFile(response, fileName, SYS_ROOT_PATH);
    }
}
